<?php

declare (strict_types=1);
/**
 * This file is part of Hyperf.
 *
 * @link     https://www.hyperf.io
 * @document https://hyperf.wiki
 * @contact  group@hyperf.io
 * @license  https://github.com/hyperf/hyperf/blob/master/LICENSE
 */
namespace App\Model;

class InformationPC extends Model
{
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected ?string $table = 'information_p_c';
    public function information()
    {
        return $this->belongsTo(Information::class, 'information_id');
    }
    public function iofo()
    {
        return ['content' => $this->content ?? '', 'origin' => $this->origin ?? '', 'origin_location' => ['lat' => $this->origin_lat ?? '', 'lng' => $this->origin_lng ?? ''], 'destination' => $this->destination ?? '', 'destination_location' => ['lat' => $this->destination_lat ?? '', 'lng' => $this->destination_lng ?? ''], 'time' => $this->time ?? '', 'number' => $this->number ?? 0];
    }
}